package com.sleep.psy.external_server.business.evaluation.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.sleep.psy.external_server.business.evaluation.entity.EvaluationReport;
import com.sleep.psy.external_server.business.evaluation.entity.dto.TrainingReport;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 测评报告 Mapper 接口
 * </p>
 *
 * @author wenliguo
 * @since 2025-08-12
 */
public interface EvaluationReportMapper extends BaseMapper<EvaluationReport> {

    /**
     * 通过用户id获取全部报告
     * @author wenliguo
     * @date 2025/8/18 09:16
     * @param userId 用户id
     * @return java.util.List<com.sleep.psy.external_server.evaluation.entity.EvaluationReport>
    */
    List<EvaluationReport> selectReportByUserId(@Param("userId") Long userId);

    /**
     * 通过用户id和量表id查询训练报告
     * @author wenliguo
     * @date 2025/9/9 11:45
     * @param userId 用户id
     * @param scaleId 量表id
     * @return java.util.List<com.sleep.psy.external_server.business.evaluation.entity.dto.TrainingReport>
    */
    List<TrainingReport> selectTrainingReport(@Param("userId") Long userId, @Param("scaleId") Integer scaleId);
}
